<?php

namespace App\Models;

use Dcat\Admin\Traits\HasDateTimeFormatter;

use Illuminate\Database\Eloquent\Model;

class PositionApply extends Model
{
	use HasDateTimeFormatter;

    protected $table = 'position_applies';


    protected $fillable = [
        'user_id',
        'position_id',
        'curriculum_vitae',
        'name'
    ];

    protected $attributes = [
        'status' => 1
    ];

    public function user()
    {
        return $this->belongsTo(User::class,'user_id');
    }

    public function position()
    {
        return $this->belongsTo(Position::class,'position_id');
    }
}
